package zyh.service.impl;

import zyh.hibernate.dao.iface.IUserDao;
import zyh.hibernate.pojo.User;
import zyh.service.iface.IUserService;

import java.util.List;

public class UserService implements IUserService{
    private IUserDao userDao;
    @Override
    public List<User> find() {
        return userDao.find("SELECT u FROM User u WHERE u.userName='admin'");
    }

    public IUserDao getUserDao() { return userDao; }

    public void setUserDao(IUserDao userDao) { this.userDao = userDao; }
}
